<%@page contentType="text/html;charset=UTF-8"%>
<%@include file="/common/taglibs.jsp"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>项目管理</title>
<script type="text/javascript"
	src="<c:url value='/scripts/global.js'/>"></script>
<script type="text/javascript">
function returnProject(){
	var checkedRadio = $("input[name='item']:checked");
	var projectId = checkedRadio.val();
	if(projectId == null){
		 alert('请选择要操作的对象!');
		 return false;
	}
	$(window.parent.setPorjectId(projectId));
	$(window.parent.close()); 
}
</script>
</head>
<body>
	<form id="mainForm" action="${ctx}/detect/detect!projwin.action" method="get"
		class="yform">
		<h2 align="left">工程列表</h2>
		<div id="filter">
			<ul>
			<li>项目编号：<input type="text" name="filter_LIKES_projKind" value="${param['filter_LIKES_projKind']}" /></li>
			<li>项目名称：<input type="text" name="filter_LIKES_projName" value="${param['filter_LIKES_projName']}" /></li>			
			</ul>
			<div class="type-button"><input type="button" class="reset" value="查询" onclick="search();" /></div>
		</div>
		<div id="content">
			<table id="contentTable">
				<tr>
					<th>工程类型</th>
					<th>项目名称</th>
					<th>开工时间</th>
					<th>完工时间</th>
				</tr>
				<c:forEach items="${page1.result}" var="proj">
					<tr>
						<td>
						<input type="radio" name="item" id="item" value="${proj.id }"></input>
						<pt:code category="3001" code="${proj.projKind}"></pt:code></td>
						<td>${proj.projName}</td>
						<td>${proj.planStartDate}</td>
						<td>${proj.planEndDate }</td>
					</tr>
				</c:forEach>
				<tr><td style="padding-left: 50px"><div class="type-button">
				<input type="button" onclick="returnProject()"value="选择" class="submit"></input></div></td>
				<td colspan="4">&nbsp;</td>
				
				</tr>
			</table>
		</div>
		
		<input type="hidden" name="page1.pageNo"  id="pageNo" value="${page1.pageNo}" /> 
<input type="hidden" name="page1.orderBy" id="orderBy" value="${page1.orderBy}" /> 
<input type="hidden" name="page1.order"   id="order" value="${page1.order}" />
<div id="pagebar">第${page1.pageNo}页, 共${page1.totalPages}页 <a
	href="javascript:jumpPage(1)">首页</a><c:if test="${page1.hasPre}">
	<a href="javascript:jumpPage(${page1.prePage})">上一页</a>
</c:if> <c:if test="${page1.hasNext}">
	<a href="javascript:jumpPage(${page1.nextPage})">下一页</a>
</c:if> <a href="javascript:jumpPage(${page1.totalPages})">末页</a></div>
	</form>
</body>
</html>
